﻿create proc sp_themPT
@TenPT nvarchar(200),
@DVT nvarchar(50)
as
declare @dem as int
select @dem=count(*) from DanhMucPT where TenPT=@TenPT
if(@dem=0)
	begin
	insert into DanhMucPT(TenPT,DVT)
	values (@TenPT,@DVT)
	select ErrCode=1
	end
else
	begin
	select ErrCode=0
	end